/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.bhatni.mockprocessor.expression;

import com.bhatni.mockprocessor.Message;

/**
 *
 * @author Viren
 */
public class AndGroupExpression extends BaseGroupConditionExpression{

    @Override
    public boolean evaluate(Message in) {
        boolean result = true;
        for (BaseConditionExpression expression:getExpressions()) {
            result &= expression.evaluate(in);
            if (!result)
                break;
        }
        return result;
    }

}
